<?php

namespace App;

use App\Models\Address;
use Illuminate\Notifications\Notifiable;
use Illuminate\Foundation\Auth\User as Authenticatable;

class User extends Authenticatable
{
    use Notifiable;

    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $guarded=['password_confirmation','file'];
    
    protected $hidden = [
        'password', 'remember_token',
    ];
    //用户表关联地址表
    public function getAddress(){
        $this->hasMany(Address::class);
    }
}
